//  generic binary search tree

#include <queue>
#include <stack>

using namespace std;

#ifndef BIVARY_SEARCH_TREE
#define BINARY_SEARCH_TREE

template<class T>
class Queue : public queue<T> {
    public:
        T dequeue() {
            T tmp =front();
            queue<T>::pop();
            return tmp;
        }
        void enqueue(const T& el) {
            push(el);
        }
};

template <class T>
class BSTNode {
    public:
        BSTNode() {
            left = right = 0;
        }
        BSTNode(const T&e, BSTNode<T> *l = 0,BSTNode<T> *r = 0) {
            el = e; left = l; right =r;
        }
        T el;
        BSTNode<T> *left, *right;
};

#endif